package com.bbcloud.dao;

import com.bbcloud.pojo.Cart;
import com.bbcloud.pojo.Product;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CartMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(Cart record);

    int insertSelective(Cart record);

    Cart selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(Cart record);

    int updateByPrimaryKey(Cart record);

    int isProductAlreadyAdded(@Param("userId")String userId, @Param("productId")String productId);

    List<Cart> selectAllCart(@Param("userId")String userId);
}